# bookstore/forms.py
from django import forms
from .models import Book

class BookForm(forms.ModelForm):
    class Meta:
        model = Book
        fields = ['name', 'description', 'publisher', 'add_date']
        widgets = {
            'add_date': forms.DateInput(attrs={'type': 'date'}),
            'publisher': forms.Select(attrs={'class': 'form-control'}),
        }